const wsModel = {
  state: {
    heartbeat:null,  //websocketHeartbeatJs
    quotation: '', // 当前股票行情数据
    pankou: '', // 股票盘口数据
    transaction: '', // 股票交易数据
    zixuanList: '', // 自选行情数据列表
    symbolSub: '', // 已订阅过的股票
    zixuanSub: '', // 自选订阅列表
    wsDapanList: [], // 大盘订阅列表
    daPanDetail: '', // 单只大盘推送详情
    wsMarket: '', // 当前页面市场推送
    wsMarketInfo: '', // 当前页面市场推送
  },
  mutations: {
    SET_HEARTBEAT: (state, heartbeat) => {
      state.heartbeat = heartbeat
    },
    setQuotation(state, status){
      state.quotation= status
    },
    setPankou(state, status){
      state.pankou= status
    },
    setTransaction(state, status){
      state.transaction= status
    },
    setSymbolSub(state, status){
      state.symbolSub= status
    },
    setZixuanSub(state, status){
      state.zixuanSub= status
    },
    setZixuanList(state, status){
      state.zixuanList= status
    },
    setWsDapanList(state, status){
      state.wsDapanList= status
    },
    setDaPanDetail(state, status){
      state.daPanDetail= status
    },
    setWsMarket(state, status){
      state.wsMarket= status
    },
    setWsMarketInfo(state, status){
      state.wsMarketInfo= status
    },
  },
  actions: {
    SETHEARTBEAT({
      commit
    }, heartbeat) {
      commit('SET_HEARTBEAT', heartbeat)
    },
    SetQuotation(context, status){
      context.commit('setQuotation', status)
    },
    SetPankou(context, status){
      context.commit('setPankou', status)
    },
    SetTransaction(context, status){
      context.commit('setTransaction', status)
    },
    SetSymbolSub(context, status){
      context.commit('setSymbolSub', status)
    },
    SetZixuanSub(context, status){
      context.commit('setZixuanSub', status)
    },
    SetZixuanList(context, status){
      context.commit('setZixuanList', status)
    },
    SetWsDapanList(context, status){
      context.commit('setWsDapanList', status)
    },
    SetDaPanDetail(context, status){
      context.commit('setDaPanDetail', status)
    },
    SetWsMarket(context, status){
      context.commit('setWsMarket', status)
    },
    SetWsMarketInfo(context, status){
      context.commit('setWsMarketInfo', status)
    },
  },
}
export default wsModel